package com.atguigu.gmall.service;

import com.atguigu.gmall.dao.DAUMapper;
import com.atguigu.gmall.dao.GVMMapper;
import com.atguigu.gmall.entity.PerHourDAU;
import com.atguigu.gmall.entity.PerHourGVM;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * Date:2021/3/19
 * Author:csw
 * Description:
 */
@Service
public class PublisherServiceImpl implements PublisherService {


    @Autowired
    private DAUMapper dauMapper;

    @Autowired
    private GVMMapper gvmMapper;

    @Override
    public Integer getDAUByDate(String date) {
        return dauMapper.getDAUByDate(date);
    }

    @Override
    public Integer getNewMidByDate(String date) {
        return dauMapper.getNewMidByDate(date);
    }

    @Override
    public List<PerHourDAU> getPerByHour(String date) {
        return dauMapper.getPerByHour(date);
    }


    @Override
    public Double getDateGVM(String date) {
        return gvmMapper.getDateGVM(date);
    }

    @Override
    public List<PerHourGVM> getHourGVM(String date) {
        return gvmMapper.getHourGVM(date);
    }
}
